package com.fanshuai.bean;

import com.fanshuai.bean.Bean1;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

@Component
public class Bean2 {
    @Resource
    private Bean1 bean1;

    public void hello() {
        System.out.println("bean2 hello");
        bean1.hello();
    }
}
